Optimal. Leaf size=38 \[ \frac {B x}{2}+\frac {C \sin (c+d x)}{d}+\frac {B \cos (c+d x) \sin (c+d x)}{2 d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.03, antiderivative size = 38, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 5, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.179, Rules used = {4132, 2715, 8,
12, 2717} \begin {gather*} \frac {B \sin (c+d x) \cos (c+d x)}{2 d}+\frac {B x}{2}+\frac {C \sin (c+d x)}{d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 8
Rule 12
Rule 2715
Rule 2717
Rule 4132
Rubi steps
\begin {align*} \int \cos ^3(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx &=B \int \cos ^2(c+d x) \, dx+\int C \cos (c+d x) \, dx\\ &=\frac {B \cos (c+d x) \sin (c+d x)}{2 d}+\frac {1}{2} B \int 1 \, dx+C \int \cos (c+d x) \, dx\\ &=\frac {B x}{2}+\frac {C \sin (c+d x)}{d}+\frac {B \cos (c+d x) \sin (c+d x)}{2 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.05, size = 35, normalized size = 0.92 \begin {gather*} \frac {4 C \sin (c+d x)+B (2 (c+d x)+\sin (2 (c+d x)))}{4 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.34, size = 38, normalized size = 1.00
method | result | size |
risch | \(\frac {B x}{2}+\frac {C \sin \left (d x +c \right )}{d}+\frac {B \sin \left (2 d x +2 c \right )}{4 d}\) | \(32\) |
derivativedivides | \(\frac {B \left (\frac {\cos \left (d x +c \right ) \sin \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )+C \sin \left (d x +c \right )}{d}\) | \(38\) |
default | \(\frac {B \left (\frac {\cos \left (d x +c \right ) \sin \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )+C \sin \left (d x +c \right )}{d}\) | \(38\) |
norman | \(\frac {B x \left (\tan ^{6}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\frac {\left (B -2 C \right ) \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}+\frac {\left (B +2 C \right ) \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}-\frac {B x}{2}-B x \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\frac {B x \left (\tan ^{8}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{2}-\frac {\left (B -2 C \right ) \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}-\frac {\left (B +2 C \right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{d}}{\left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )^{3} \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}\) | \(161\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.29, size = 34, normalized size = 0.89 \begin {gather*} \frac {{\left (2 \, d x + 2 \, c + \sin \left (2 \, d x + 2 \, c\right )\right )} B + 4 \, C \sin \left (d x + c\right )}{4 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 1.90, size = 29, normalized size = 0.76 \begin {gather*} \frac {B d x + {\left (B \cos \left (d x + c\right ) + 2 \, C\right )} \sin \left (d x + c\right )}{2 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \left (B + C \sec {\left (c + d x \right )}\right ) \cos ^{3}{\left (c + d x \right )} \sec {\left (c + d x \right )}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 82 vs.
\(2 (34) = 68\).
time = 0.46, size = 82, normalized size = 2.16 \begin {gather*} \frac {{\left (d x + c\right )} B - \frac {2 \, {\left (B \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - 2 \, C \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - B \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 2 \, C \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 1\right )}^{2}}}{2 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 2.45, size = 31, normalized size = 0.82 \begin {gather*} \frac {B\,x}{2}+\frac {B\,\sin \left (2\,c+2\,d\,x\right )}{4\,d}+\frac {C\,\sin \left (c+d\,x\right )}{d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________